import _fetch from "api_xukaiyu/fetch";
/**
 * 登录之后--修改手机号--发送验证码
 * @param { Object } data 请求参数
 * {
 *   mobile 手机号
 *   challenge 极验验证码
 * }
 */
export function sendMobileCode(data) {
  return _fetch({
    url: "app/user/sendMobileCode",
    method: "POST",
    data: data,
    headers: {}
  });
}
/**
 * 查询我的信息
 */
export function query_info(data) {
  return _fetch({
    url: "app/user/query_info",
    method: "POST",
    data: data,
    headers: {}
  });
}
/**
 * 登录之后--修改手机号--验证
 * @param { Object } data 请求参数
 * {
 *   mobile undefined
 *   code undefined
 *   appType undefined
 * }
 */
export function checkMobileCode(data) {
  return _fetch({
    url: "app/user/checkMobileCode",
    method: "POST",
    data: data,
    headers: {}
  });
}

export function bindEmail(data) {
  return _fetch({
    url: "app/user/bindEmail",
    method: "POST",
    data: data,
    headers: {
      'content-type': 'application/x-www-form-urlencoded'
    }
  });
}

